<div class="page">
<%= render :partial => 'profiles/tabs', :locals => {:selected_tab=>'Permalinks'} %>

<div class="tabs-panel marginbottom10 ">
	<% exporters = Internal.qprofile_exporters.exportersForLanguage(@profile.language()) %>
	<br/>
	<table class="data without-header marginbottom10" id="permalinks-table">
      <tbody>
	  <tr class="even">
	    <td width="1%" nowrap>
	      <%= message('quality_profiles.export_all_rules') -%>
	    </td>
	    <td>
	      <% permalink = url_for :controller => 'profiles', :action => 'export', :language => @profile.language(), :name => url_encode(@profile.name()), :only_path => false %>
	      <span class="small"><%= link_to permalink, permalink %></span>
	    </td>
	  </tr>
	  <% exporters.to_a.sort{|x,y| x.getName() <=> y.getName()}.each do |exporter| %>
	    <tr class="<%= cycle('odd','even') -%>">
	      <td width="1%" nowrap>
	        <%= h exporter.getName() -%>
	      </td>
	      <td>
	        <% permalink=url_for :controller => 'profiles', :action => 'export', :language => @profile.language(), :name => url_encode(@profile.name()), :format => exporter.getKey(), :only_path => false %>
	        <span class="small"><%= link_to permalink, permalink, :id => "export_" + exporter.getKey().to_s + "_" + @profile.key() %></span>
	      </td>
	    </tr>
	  <% end %>
	  </tbody>
	</table>
</div>
</div>
